package com.wzh.yebServe.controller;

import com.wzh.yebServe.pojo.Menu;
import com.wzh.yebServe.service.IMenuService;
import com.wzh.yebServe.service.IUserService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Author wzh
 * @create 2022/11/12 20:35
 * @Description:菜单接口
 */
@RestController
@RequestMapping("/system/cfg")
public class MenuController {
    @Autowired
    private IMenuService iMenuService;

    @ApiOperation("通过用户id查询菜单列表")
    @GetMapping("/menu")
    public List<Menu> getMenusByAdminId(){
        return iMenuService.getMenusByAdminId();
    }

}
